package com.sg.service.biz.app.nb;

import cn.hutool.core.bean.BeanUtil;
import com.sg.dto.biz.app.req.ImplementObtainSafetyArgumentsReqDto;
import com.sg.dto.biz.app.res.ImplementObtainSafetyArgumentsRespDto;
import org.apache.skywalking.apm.toolkit.trace.Tag;
import org.apache.skywalking.apm.toolkit.trace.Tags;
import org.apache.skywalking.apm.toolkit.trace.Trace;
import org.springframework.stereotype.Service;

/**
 * @author ： 手工接入方法
 * @version 1.0
 * @since 2022/5/28 15:32
 */
@Service
public class NbSecurity {
    /**
     * code:receptionService
     * name:M2-约定允许操作
     * desc:undefined
     * gen by moon at 1/22/2023, 5:44:38 PM
     **/
    @Trace(operationName = "M2-约定允许操作")
    @Tags({@Tag(key = "参数", value = "arg[0]"),
            @Tag(key = "返回值", value = "returnedObj")})
    public ObtainReceiveFieldsRespDto obtainReceiveFields(ObtainReceiveFieldsReqDto reqDto) {
        return BeanUtil.toBean(reqDto, ObtainReceiveFieldsRespDto.class);

    }

    /**
     * code:obtainSafetyArguments
     * name:M3执行获取安全参数（特殊方法）
     * desc:undefined
     * gen by moon at 2/5/2023, 10:52:58 PM
     **/
    @Trace(operationName = "M3执行获取安全参数（特殊方法）")
    @Tags({@Tag(key = "参数", value = "arg[0]"),
            @Tag(key = "返回值", value = "returnedObj")})
    public ImplementObtainSafetyArgumentsRespDto implementObtainSafetyArguments(ImplementObtainSafetyArgumentsReqDto reqDto) {
        return BeanUtil.toBean(reqDto, ImplementObtainSafetyArgumentsRespDto.class);
    }

    /**
     * code:receptionService
     * name:M3约定钥匙操作类型为“操作异常”
     * desc:undefined
     * gen by moon at 5/9/2023, 4:46:47 PM
     **/
    @Trace(operationName = "M3约定钥匙操作类型为“操作异常”")
    @Tags({@Tag(key = "参数", value = "arg[0]"),
            @Tag(key = "返回值", value = "returnedObj")})
    public ImplementAcceptFieldRespDto implementAcceptField(ImplementAcceptFieldReqDto reqDto) {
        return BeanUtil.toBean(reqDto, ImplementAcceptFieldRespDto.class);
    }
    //手工接入方法
}
